3.8 \(\int \frac{\csc ^4(x)}{i+\tan (x)} \, dx\)

Optimal. Leaf size=19 \[ -\frac{\cot ^2(x)}{2}+\frac{1}{3} i \cot ^3(x) \]

[Out]

-Cot[x]^2/2 + (I/3)*Cot[x]^3

________________________________________________________________________________________

Rubi [A]  time = 0.038832, antiderivative size = 19, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.231, Rules used = {3516, 848, 43} \[ -\frac{\cot ^2(x)}{2}+\frac{1}{3} i \cot ^3(x) \]

Antiderivative was successfully verified.

[In]

Int[Csc[x]^4/(I + Tan[x]),x]

[Out]

-Cot[x]^2/2 + (I/3)*Cot[x]^3

Rule 3516

Int[sin[(e_.) + (f_.)*(x_)]^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Dist[b/f, Subst[Int
[(x^m*(a + x)^n)/(b^2 + x^2)^(m/2 + 1), x], x, b*Tan[e + f*x]], x] /; FreeQ[{a, b, e, f, n}, x] && IntegerQ[m/
2]

Rule 848

Int[((d_) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d + e*x)
^(m + p)*(f + g*x)^n*(a/d + (c*x)/e)^p, x] /; FreeQ[{a, c, d, e, f, g, m, n}, x] && NeQ[e*f - d*g, 0] && EqQ[c
*d^2 + a*e^2, 0] && (IntegerQ[p] || (GtQ[a, 0] && GtQ[d, 0] && EqQ[m + p, 0]))

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int \frac{\csc ^4(x)}{i+\tan (x)} \, dx &=\operatorname{Subst}\left (\int \frac{1+x^2}{x^4 (i+x)} \, dx,x,\tan (x)\right )\\ &=\operatorname{Subst}\left (\int \frac{-i+x}{x^4} \, dx,x,\tan (x)\right )\\ &=\operatorname{Subst}\left (\int \left (-\frac{i}{x^4}+\frac{1}{x^3}\right ) \, dx,x,\tan (x)\right )\\ &=-\frac{1}{2} \cot ^2(x)+\frac{1}{3} i \cot ^3(x)\\ \end{align*}

Mathematica [A]  time = 0.0175136, size = 29, normalized size = 1.53 \[ -\frac{1}{3} i \cot (x)-\frac{\csc ^2(x)}{2}+\frac{1}{3} i \cot (x) \csc ^2(x) \]

Antiderivative was successfully verified.

[In]

Integrate[Csc[x]^4/(I + Tan[x]),x]

[Out]

(-I/3)*Cot[x] - Csc[x]^2/2 + (I/3)*Cot[x]*Csc[x]^2

________________________________________________________________________________________

Maple [A]  time = 0.038, size = 15, normalized size = 0.8 \begin{align*} -{\frac{1}{2\, \left ( \tan \left ( x \right ) \right ) ^{2}}}+{\frac{{\frac{i}{3}}}{ \left ( \tan \left ( x \right ) \right ) ^{3}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csc(x)^4/(I+tan(x)),x)

[Out]

-1/2/tan(x)^2+1/3*I/tan(x)^3

________________________________________________________________________________________

Maxima [A]  time = 1.36622, size = 16, normalized size = 0.84 \begin{align*} -\frac{i \,{\left (-3 i \, \tan \left (x\right ) - 2\right )}}{6 \, \tan \left (x\right )^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)^4/(I+tan(x)),x, algorithm="maxima")

[Out]

-1/6*I*(-3*I*tan(x) - 2)/tan(x)^3

________________________________________________________________________________________

Fricas [B]  time = 1.99596, size = 109, normalized size = 5.74 \begin{align*} \frac{2 \,{\left (6 \, e^{\left (4 i \, x\right )} - 3 \, e^{\left (2 i \, x\right )} + 1\right )}}{3 \,{\left (e^{\left (6 i \, x\right )} - 3 \, e^{\left (4 i \, x\right )} + 3 \, e^{\left (2 i \, x\right )} - 1\right )}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)^4/(I+tan(x)),x, algorithm="fricas")

[Out]

2/3*(6*e^(4*I*x) - 3*e^(2*I*x) + 1)/(e^(6*I*x) - 3*e^(4*I*x) + 3*e^(2*I*x) - 1)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)**4/(I+tan(x)),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [A]  time = 1.41731, size = 16, normalized size = 0.84 \begin{align*} -\frac{3 \, \tan \left (x\right ) - 2 i}{6 \, \tan \left (x\right )^{3}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)^4/(I+tan(x)),x, algorithm="giac")

[Out]

-1/6*(3*tan(x) - 2*I)/tan(x)^3